#ifndef LED_H
#define LED_H

#include "User_Def.h"

#define LED u16
#define LED_PORT GPIOA

#define LED_MAIN_PIN GPIO_PIN_12
#define LED0_PIN GPIO_PIN_7
#define LED1_PIN GPIO_PIN_5
#define LED2_PIN GPIO_PIN_6
#define LED3_PIN GPIO_PIN_0
#define LED4_PIN GPIO_PIN_1
#define LED5_PIN GPIO_PIN_2
#define LED6_PIN GPIO_PIN_3
#define LED7_PIN GPIO_PIN_4

extern u8 LEDs_Green_Size;
extern LED LEDs_Green[];

void LED_Init(void);
void LED_Main_Close(void);

void LED_On(LED led);
void LED_Off(LED led);

void LED_Toggle(LED led);

void LED_OnAll(LED leds[], u8 size);
void LED_OffAll(LED leds[], u8 size);
// 传1奇数位灯亮，0偶数位灯亮
void LED_Odd_Even_Toggle(u8 cur);

#endif /* LED_H */